﻿using System.Web.Mvc;

namespace DataProj.Areas.BackSys
{
    public class BackSysAreaRegistration : AreaRegistration 
    {
        public override string AreaName 
        {
            get 
            {
                return "BackSys";
            }
        }

        public override void RegisterArea(AreaRegistrationContext context) 
        {
            //context.MapRoute(
            //    "BackSys_default",
            //    "BackSys/{controller}/{action}/{id}",
            //    new { action = "Index", id = UrlParameter.Optional }
            //);

            //context.MapRoute(
            //    "BackSys_default",
            //    "BackSys/{controller}/{action}/{id}",
            //    new {controller="Home", action = "Index", id = UrlParameter.Optional }
            //);
            context.MapRoute(
                "BackSys_default",
                "BackSys/{controller}/{action}/{id}",
                //BackSys/Home/ManagerLogin
                new { controller = "Home", action = "Index", id = UrlParameter.Optional },
                new string[] { "DataProj.Areas.BackSys.Controllers" }
            );
        }
    }
}